Enter topic summary (Optional) - remove all text if not used
Users can customize the header, rows, and borders within a table through the use of a custom stylesheet. After configuring the custom stylesheet, users can now specify table shading through the TableStyle option.Note: The font-size specified for the table styles below is what will actually be used. Normally adjustments are performed on certain fonts to make them larger than specified if the font does not meet legal size requirements but that adjustment will not be done for custom tables.
- Within the Custom_WKFS_Styleguide.xsl file, navigate to the Tables section. Within each style <x> table section modify the following:
- style<x>-header-attrs - font, color, background color, font weight, font style, text decoration, and font size variables for the table header.
- style<x>-body-attrs - font size, color, and font family variables for the table rows.
- style<x>-border-attrs - border size, style, and width variables for the table borders.
<!-- Begin options for style1 table -->
<xsl:attribute-set name="style1-header-attrs">
<xsl:attribute name="font-family">Times New Roman</xsl:attribute>
<xsl:attribute name="color">blue</xsl:attribute>
<xsl:attribute name="background-color">pink</xsl:attribute>
<xsl:attribute name="font-weight">normal</xsl:attribute>
<xsl:attribute name="font-style">italic</xsl:attribute>
<xsl:attribute name="text-decoration">underline</xsl:attribute>
<xsl:attribute name="font-size">16pt</xsl:attribute>
</xsl:attribute-set>
<xsl:attribute-set name="style1-body-attrs">
<xsl:attribute name="font-size">13pt</xsl:attribute>
<xsl:attribute name="color">purple</xsl:attribute>
<xsl:attribute name="font-family">Comic</xsl:attribute>
</xsl:attribute-set>
<xsl:template name="style1-border-attrs">
<xsl:attribute name="border-color">red</xsl:attribute>
<xsl:attribute name="border-style">dotted</xsl:attribute>
<xsl:attribute name="border-width">1.25pt</xsl:attribute>
</xsl:template>
<xsl:variable name="style1-TableBodyEvenRowBackgroundColor" select="'green'" />
<xsl:variable name="style1-TableBodyOddRowBackgroundColor" select="'yellow'" />
<!-- End options for style1 table -->
- Save the changes.
- Within the Requirements Editor, create a table. On the Table element, right-click and select Add Attribute/TableStyle.
- Within the TableStyle attribute, double-click No Value and select the desired Style (as created in the Custom_WKFS_Styleguide.xsl file). Return to the .xsl file to make any further updates to a particular TableStyle style.
Note: The particular TableStyle selection will override other attributes selected elsewhere in the table element: font, weight, color, etc.